import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)

export default new Vuex.Store({
  state: {
    rightList: [],
    userInfo: {} || localStorage.getItem('userInfo') // 用户信息
  },
  mutations: {
    setRightList(state, data) {
      state.rightList = data
    },
    setUserInfo(state, data) {
      state.userInfo = data
    }
  },
  actions: {},
  modules: {}
})
